<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:cc="http://java.sun.com/jsf/composite"
                template="./template.xhtml">


    <ui:define name="content">
        <h1><h:outputText value="#{msgs.misCompras}:"/></h1>
        <h:panelGrid width="100%" rendered="#{!empty historicoVentas.historicoVentas}">
        <h:form>
            <h:dataTable styleClass="tablasSt" value="#{historicoVentas.historicoVentas}" var="item" cellpadding="2"
                         cellspacing="0" rowClasses="odd_row,even_row" rules="all">
                <h:column>
                    <f:facet name="header">
                        <h:outputText value="#{msgs.referenciaAbr}"/>
                    </f:facet>
                    <h:outputText value="#{item.id}"/>
                </h:column>
                <h:column>
                    <f:facet name="header">
                        <h:outputText value="#{msgs.fecha}"/>
                    </f:facet>
                    <h:outputText value="#{item.fecha}"/>
                </h:column>
                <h:column>
                    <f:facet name="header">

                    </f:facet>
                    <h:commandButton styleClass="minimunButton" value="#{msgs.masInfo}" action="#{historicoVentas.verLineaCompra}">
                    </h:commandButton>
                </h:column>
            </h:dataTable>
        </h:form>
    </h:panelGrid>
        <h:panelGrid rendered="#{empty historicoVentas.historicoVentas}">
            <h:outputText value="#{msgs.noEncontradoVenta}"/>
        </h:panelGrid>
    </ui:define>

</ui:composition>
